﻿@using PraceDyplomowe2.Models
<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8" />
        <title>@ViewBag.Title - Prace Dyplomowe</title>
        <link href="~/favicon.ico" rel="shortcut icon" type="image/x-icon" />
        <meta name="viewport" content="width=device-width" />
        @Styles.Render("~/Content/css")

        @Scripts.Render("~/bundles/modernizr")
    </head>
    <body>
        <header>
            <div class="content-wrapper top">
                <div class="float-left">
                    <div class="top-right"></div>
                    <p class="site-title">@Html.ActionLink("System do obsługi prac dyplomowych", "Index", "Home")</p>
                    <div class="top-left"></div>
                </div>
                <div class="float-right">
                  <section id="login">
                         @Html.Partial("_LoginPartial")
                    </section>
                    <nav>
                        <ul id="menu">
                            <li>@Html.ActionLink("Strona główna", "Index", "Home")</li>
                            
                            @if (((RolePrincipal) User).IsInRole(Rola.DziekanNazwa)
                                || ((RolePrincipal) User).IsInRole(Rola.PromotorNazwa))
                            {
                                <li id="lista">
                                    <a href="#">Listy</a>
                                    <ul>
                                        <li>@Html.ActionLink("Tematy", "Index", "Tematy")</li>
                                        <li>@Html.ActionLink("Promotorzy", "Index", "ProfilPromotora")</li>
                                        <li>@Html.ActionLink("Studenci", "Index", "ProfilStudenta")</li>
                                    </ul>
                                </li>
                            }
                            
                             @if (((RolePrincipal) User).IsInRole(Rola.StudentNazwa))
                             {
                                 <li id="lista">
                                     <a href="#">Listy</a>
                                     <ul>
                                         <li>@Html.ActionLink("Tematy", "Index", "Tematy")</li>
                                         <li>@Html.ActionLink("Promotorzy", "Index", "ProfilPromotora")</li>
                                     </ul>
                                 </li>
                             }
                            
                            @if (((RolePrincipal) User).IsInRole(Rola.AdministratorNazwa))
                            {
                                <li id="lista">
                                     <a href="#">Opcje</a>
                                    <ul>
                                        <li>@Html.ActionLink("Nowe konto", "Register", "Administracja")</li>
                                        <li>@Html.ActionLink("Lista Promotorów", "ListaPromotorow", "Administracja")</li>
                                        <li>@Html.ActionLink("Lista Studentów", "ListaStudentow", "Administracja")</li>
                                    </ul>
                                 </li>
                            }
                            
                            <li>
                                @if (((RolePrincipal) User).IsInRole(Rola.DziekanNazwa))
                                {
                                    @Html.ActionLink("Mój profil", "Details", "ProfilPromotora")
                                } 
                                else if (((RolePrincipal) User).IsInRole(Rola.PromotorNazwa))
                                {
                                    @Html.ActionLink("Mój profil", "Details", "ProfilPromotora")
                                }
                                @if (((RolePrincipal) User).IsInRole(Rola.StudentNazwa))
                                {
                                    @Html.ActionLink("Mój profil", "Details", "ProfilStudenta")
                                }
                            </li>
                        </ul>
                        
                    </nav>
                </div>
            </div>
        </header>
        <div id="body">
            @RenderSection("featured", required: false)
            <section class="content-wrapper main-content clear-fix">
                @RenderBody()
            </section>
        </div>
        <footer>
            <div class="content-wrapper">
                <div class="float-left">
                    <p>&copy; @DateTime.Now.Year - My ASP.NET MVC Application</p>
                </div>
            </div>
        </footer>

        @Scripts.Render("~/bundles/jquery")
        
        @RenderSection("scripts", required: false)

    </body>
</html>
